Numpy

ValueError: numpy.ndarray size changed, may indicate binary incompatibility. Expected 88 from C header, got 80 from PyObject

When import cpprb, I got ValueError: numpy.ndarray size changed, may indicate binary incompatibility. Expected 88 from C header, got 80 from PyObject. Recently, NumPy has changed its ABI at version

numpy.ndarray + int can return different dtype of numpy.ndarray

This is based on a cpprb bug ( issue 112). In cpprb, numpy.ndarray ( Ref.) is used for internal memory. numpy.zeros(shape,dtype=data_type) initialized a certain shape and data type buffer. Conveniently,

setup.py for Cython / Numpy based project

This post is a English version of this Japanese post. One of the common troubles for developing Cython/ Numpy based C/C++ extension package is setup.py. Ideally, all packages should be

cython を使って、c++ std::vector と numpy.ndarray とでメモリを共有する方法

<追記> Cython のコードのインデントがブログ上では壊れ